package com.xiaodu.yaml.properties;

import org.springframework.boot.context.properties.ConfigurationProperties;

import java.util.Date;
import java.util.List;
import java.util.Map;

/**
 * @author: dutianjie
 * @date: 2021/3/22
 * @version: v1.0.0
 * @description: 描述
 * @email: dutianjie@thunisoft.com
 **/
@ConfigurationProperties(prefix = "person")
public class UserProperties {

    private String name;

    //    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private Date birthday;

    private List<String> hobby;

    private Integer age;

    private Map<String, String> family;

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public Date getBirthday() {
        return birthday;
    }

    public void setBirthday(Date birthday) {
        this.birthday = birthday;
    }

    public List<String> getHobby() {
        return hobby;
    }

    public void setHobby(List<String> hobby) {
        this.hobby = hobby;
    }

    public Integer getAge() {
        return age;
    }

    public void setAge(Integer age) {
        this.age = age;
    }

    public Map<String, String> getFamily() {
        return family;
    }

    public void setFamily(Map<String, String> family) {
        this.family = family;
    }

    @Override
    public String toString() {
        return "UserProperties{" +
                "name='" + name + '\'' +
                ", birthday=" + birthday +
                ", hobby=" + hobby +
                ", age=" + age +
                ", family=" + family +
                '}';
    }
}
